﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Xml;

namespace Syfuhs.APIWrappers.LiveMeeting
{
    public class UserSettings : ParsedType
    {
        public UserSettings() { }
        
        public bool EnableCustomFramesPrivilege { get; set; }
        
        public bool AudioAllowCALLME { get; set; }
        
        public string SeatPrompt { get; set; }
        
        public AudienceEntryControl AudienceEntryControl { get; set; }
        
        public bool EcrWhiteboardPrivilege { get; set; }
        
        public bool EcrChatPrivilege { get; set; }
        
        public bool EcrQAPrivilege { get; set; }
        
        public bool EcrTextpagePrivilege { get; set; }
        
        public bool EcrAnnotationsPrivilege { get; set; }
        
        public bool EcrSharednotesPrivilege { get; set; }
        
        public bool EcrHandoutsPrivilege { get; set; }
        
        public bool RecordingPreference { get; set; }
        
        public string SeatLabelGreen { get; set; }
        
        public string FirstName { get; set; }
        
        public PrintingOption PrintPDFPreference { get; set; }
        
        public CultureInfo Locale { get; set; }
        
        public DeleteContentTimeType DeleteContentTimeType { get; set; }
        
        public SetRecordingEntryControl SetRecordingEntryControl { get; set; }
        
        public bool RecordingPrivilege { get; set; }
        
        public DateTime CreateTime { get; set; }
        
        public double MeetingDuration { get; set; }
        
        public double MeetingSize { get; set; }
        
        public string AudioTollCountryCode { get; set; }
        
        public bool AllowChat { get; set; }
        
        public string InfoP { get; set; }
        
        public string SeatLabelRed { get; set; }
        
        public string AudioTollCityCode { get; set; }
        
        public bool Registration { get; set; }
        
        public string AudioTollFreeCityCode { get; set; }
        
        public bool ShowAudioTollNumber { get; set; }
        
        public bool EnableSeatingChart { get; set; }
        
        public bool QaConsole { get; set; }
        
        public bool ShowEndSessionButton { get; set; }
        
        public double Version { get; set; }
        
        public string SeatLabelYellow { get; set; }
        
        public PrintingOption PrintPDFPrivilege { get; set; }
        
        public bool EnableAudioBroadcast { get; set; }
        
        public double DeleteContentTimeAmount { get; set; }
        
        public ApplicationSharingOption ApplicationSharingPrivilege { get; set; }
        
        public bool CustomFramesEnabled { get; set; }
        
        public bool AllowRequestControlApplicationSharing { get; set; }
        
        public string AudioDialingStringPre { get; set; }
        
        public bool PublishNetShow { get; set; }
        
        public ApplicationSharingOption ApplicationSharingPreference { get; set; }
        
        public bool EnableLobbyEmail { get; set; }
        
        public double AudienceCustomFrameHt { get; set; }
        
        public bool FreeEntry { get; set; }
        
        public bool RecordingRegistration { get; set; }
        
        public bool PublishRealAudio { get; set; }
        
        public double PresenterCustomFrameHt { get; set; }
        
        public bool PublishLiveMeetingMedia { get; set; }
        
        public bool PublishWindowsMediaMovie { get; set; }
        
        public DateTime ModifyTime { get; set; }
        
        public string SeatLabelBlue { get; set; }
        
        public string InfoA { get; set; }
        
        public bool PublishNonStreamedAudio { get; set; }
        
        public bool IsOrganizer { get; set; }
        
        public bool ShowAudioTollFreeNumber { get; set; }
        
        public bool IsAdministrator { get; set; }
        
        public ApplicationSharingColor ApplicationSharingColor { get; set; }
        
        public string AudioTollNumber { get; set; }
        
        public bool RecordingDownloadPermission { get; set; }
        
        public InitialSeatColor InitialSeatColor { get; set; }
        
        public string TimeZone { get; set; }
        
        public bool AudioEmbedded { get; set; }
        
        public string SeatLabelPurple { get; set; }
        
        public string LastName { get; set; }
        
        public string AudioDialingStringPost { get; set; }
        
        public string AudioTollFreeCountryCode { get; set; }
        
        public string AllowedIPs { get; set; }
        
        public bool DeleteContentAfterMeetingEnds { get; set; }
        
        public string Email { get; set; }
        
        public bool EnableLobby { get; set; }
        
        public bool EasyAssistEnabled { get; set; }
        
        public string EasyAssistSummaryMailId { get; set; }
        
        public PresenterEntryControl PresenterEntryControl { get; set; }
        
        public bool AllowSendEmail { get; set; }
        
        public DateTime Time { get; set; }
        
        public double RecordingExpirationTimeAmount { get; set; }
        
        public bool AudioVOIPPrivilege { get; set; }
        
        public RecordingExpirationTimeType RecordingExpirationTimeType { get; set; }
        
        public bool AudioBroadcastPrivilege { get; set; }
        
        public double LinesPerPage { get; set; }
        
        public bool EnablePersonalRecordingPresenter { get; set; }
        
        public string Opaque1 { get; set; }
        
        public bool EnablePersonalRecordingAttendee { get; set; }
        
        public MeetingPrivilege MeetingPrivilege { get; set; }
        
        public string Uid { get; set; }
        
        public bool EnableAudioVOIP { get; set; }
        
        public PersonalRecordingPrivilege PersonalRecordingPrivilege { get; set; }
        
        public string Company { get; set; }
        
        public bool EnableRecordingExpiration { get; set; }
        
        public bool AllowVideoEnable { get; set; }
        
        public string AudioConferenceProvider { get; set; }

        // allowChat
        // allowedFileExtensions
        // allowRequestControlApplicationSharing
        // allowSendEmail
        // allowVideoEnable
        // applicationSharingColor
        // applicationSharingPreference
        // applicationSharingPrivilege
        // audienceCustomFrameHt
        // audienceCustomFrameURL
        // audienceEntryControl
        // audioAllowCALLME
        // audioBroadcastPrivilege
        // audioConferenceProvider
        // audioDialingStringPost
        // audioDialingStringPre
        // audioEmbedded
        // audioLeaderCode
        // audioParticipantCode
        // audioTollCityCode
        // audioTollCountryCode
        // audioTollFreeCityCode
        // audioTollFreeCountryCode
        // audioTollFreeNumber
        // audioTollNumber
        // audioVOIPPrivilege
        // billing
        // company
        // createTime
        // customFramesEnabled
        // deleteContentAfterMeetingEnds
        // deleteContentTimeAmount
        // deleteContentTimeType
        // easyAssistEnabled
        // ecrAnnotationsPrivilege
        // ecrChatPrivilege
        // ecrHandoutsPrivilege
        // ecrQAPrivilege
        // ecrSharednotesPrivilege
        // ecrTextpagePrivilege
        // ecrWhiteboardPrivilege
        // email
        // enableAudioBroadcast
        // enableAudioVOIP
        // enableFileTransfer
        // enablePersonalRecordingPresenter
        // enablePersonalRecordingAttendee
        // enableCustomFramesPrivilege
        // enableLobby
        // enableLobbyEmail
        // enableRecordingExpiration
        // enableSeatingChart
        // expireTime
        // firstName
        // freeEntry
        // infoA
        // infoP
        // initialSeatColor
        // isAdministrator
        // isOrganizer
        // lastName
        // linesPerPage
        // lobbyMessage
        // locale
        // meetingDuration
        // meetingSize
        // modifyTime
        // opaque1
        // personalRecordingPrivilege
        // presenterCustomFrameHt
        // presenterCustomFrameURL
        // presenterEntryControl
        // printPDFPreference
        // printPDFPrivilege
        // qaConsole
        // recordingDownloadPermission
        // recordingExpirationTimeAmount
        // recordingExpirationTimeType
        // recordingPreference
        // recordingPrivilege
        // recordingRegistration
        // registration
        // seatLabelBlue
        // seatLabelGreen
        // seatLabelPurple
        // seatLabelRed
        // seatLabelYellow
        // seatPrompt
        // setRecordingEntryControl
        // showAudioTollFreeNumber
        // showAudioTollNumber
        // showEndSessionButton
        // status
        // tag
        // tagID
        // time
        // timeZone
        // type
        // userName
    }

    static class UserResponseParser
    {
        public static UserSettings Parse(XmlDocument response)
        {
            return (UserSettings)TypeParser.ParseXmlNodes(new UserSettings(), response.SelectNodes("PlaceWareConfCenter/GetUser7Reply/User/OptionList"));
        }
    }
}
